package com.sc.VenusQueryBeta.ui.activites.details;

import android.app.Activity;
import android.os.Bundle;
import android.support.design.widget.AppBarLayout;
import android.support.v7.widget.Toolbar;
import android.view.View;
import android.widget.ImageButton;

import com.hengjun.kingstar.sdk.utils.HtmlUtils;
import com.hjhrq1991.library.tbs.TbsBridgeWebView;
import com.sc.VenusQueryBeta.R;
import com.sc.VenusQueryBeta.constant.Constants;

import butterknife.BindView;
import butterknife.ButterKnife;

public class TestDetailActivity extends Activity {

    @BindView(R.id.webView)
    TbsBridgeWebView webView;
    @BindView(R.id.about_register_back)
    ImageButton aboutRegisterBack;
    @BindView(R.id.toolbar)
    Toolbar toolbar;
    @BindView(R.id.about_kingstar_infornation)
    AppBarLayout aboutKingstarInfornation;
    private String detail;

    @Override
    protected void onCreate(Bundle savedInstanceState) {
        super.onCreate(savedInstanceState);
        setContentView(R.layout.activity_test_detail);
        ButterKnife.bind(this);
        Bundle extras = getIntent().getExtras();

        webView.setVerticalScrollBarEnabled(false); //垂直不显示
        webView.setHorizontalScrollBarEnabled(false);//水平不显示
        if (extras != null) {
            detail = extras.getString(Constants.BANNER_DETAIL);
            webView.loadData(detail, HtmlUtils.MIME_TYPE, HtmlUtils.ENCODING);
        }

        aboutRegisterBack.setOnClickListener(new View.OnClickListener() {
            @Override
            public void onClick(View v) {
                finish();
            }
        });
    }
}
